<?php 
/* Template Name: Feiras Locais */

$post = $wp_query->post;
get_header();
?>

<style type="text/css">
.cont-logo-parque-zoo {margin: auto; display: table;}
.cont-outra-info {width: 400px; height: auto; margin: auto; display: table;}
.gmap3 {margin: 20px auto; border: 1px dashed #C0C0C0; width: 195px; height: 125px;}

#basic-accordian{padding:5px;width:630px;z-index:2;}
.accordion_headings{padding:10px;background:#99cc00;color:#ffffff;font-weight:bold;height:40px;font-size:20px;}
.accordion_headings:hover{background:#00ccff;}
.accordion_child{padding:5px;}
.header_highlight{background:#00ccff;}

.cont-logo-parque-zoo {margin: auto; display: table;}
.cont-outra-info {width: 400px; height: auto; margin: auto; display: table;}
.gmap3 {margin: 20px auto; border: 1px dashed #C0C0C0; width: 195px; height: 125px;}

</style>

<script type="text/javascript">
// Prototype Method to get the element based on ID
function $(d){return document.getElementById(d);}

// set or get the current display style of the div
function dsp(d,v){
	if(v==undefined){return d.style.display;
	}else{d.style.display=v;}
}

// set or get the height of a div.
function sh(d,v){
	// if you are getting the height then display must be block to return the absolute height
	if(v==undefined){
		if(dsp(d)!='none'&& dsp(d)!=''){return d.offsetHeight;}
		viz = d.style.visibility;
		d.style.visibility = 'hidden';
		o = dsp(d);
		dsp(d,'block');
		r = parseInt(d.offsetHeight);
		dsp(d,o);
		d.style.visibility = viz;
		return r;
	}else{d.style.height=v;}
}
/*
* Variable 'S' defines the speed of the accordian
* Variable 'T' defines the refresh rate of the accordian
*/
s=7;
t=10;
//Collapse Timer is triggered as a setInterval to reduce the height of the div exponentially.
function ct(d){
	d = $(d);
	if(sh(d)>0){
		v = Math.round(sh(d)/d.s);
		v = (v<1) ? 1 :v ;
		v = (sh(d)-v);
		sh(d,v+'px');
		d.style.opacity = (v/d.maxh);
		d.style.filter= 'alpha(opacity='+(v*100/d.maxh)+');';
	}else{
		sh(d,0);
		dsp(d,'none');
		clearInterval(d.t);
	}
}
//Expand Timer is triggered as a setInterval to increase the height of the div exponentially.
function et(d){
	d = $(d);
	if(sh(d)<d.maxh){
		v = Math.round((d.maxh-sh(d))/d.s);
		v = (v<1) ? 1 :v ;
		v = (sh(d)+v);
		sh(d,v+'px');
		d.style.opacity = (v/d.maxh);
		d.style.filter= 'alpha(opacity='+(v*100/d.maxh)+');';
	}else{
		sh(d,d.maxh);
		clearInterval(d.t);
	}
}
// Collapse Initializer
function cl(d){
	if(dsp(d)=='block'){
		clearInterval(d.t);
		d.t=setInterval('ct("'+d.id+'")',t);
	}
}
//Expand Initializer
function ex(d){
	if(dsp(d)=='none'){
		dsp(d,'block');
		d.style.height='0px';
		clearInterval(d.t);
		d.t=setInterval('et("'+d.id+'")',t);
	}
}
// Removes Classname from the given div.
function cc(n,v){
	s=n.className.split(/\s+/);
	for(p=0;p<s.length;p++){
		if(s[p]==v+n.tc){
			s.splice(p,1);
			n.className=s.join(' ');
			break;
		}
	}
}
//Accordian Initializer
function Accordian(d,s,tc){
	// get all the elements that have id as content
	l=$(d).getElementsByTagName('div');
	c=[];
	for(i=0;i<l.length;i++){
		h=l[i].id;
		if(h.substr(h.indexOf('-')+1,h.length)=='content'){c.push(h);}
	}
	sel=null;
	//then search through headers
	for(i=0;i<l.length;i++){
		h=l[i].id;
		if(h.substr(h.indexOf('-')+1,h.length)=='header'){
			d=$(h.substr(0,h.indexOf('-'))+'-content');
			d.style.display='none';
			d.style.overflow='hidden';
			d.maxh =sh(d);
			d.s=(s==undefined)? 7 : s;
			h=$(h);
			h.tc=tc;
			h.c=c;
			// set the onclick function for each header.
			h.onclick = function(){
				for(i=0;i<this.c.length;i++){
					cn=this.c[i];
					n=cn.substr(0,cn.indexOf('-'));
					if((n+'-header')==this.id){
						ex($(n+'-content'));
						n=$(n+'-header');
						cc(n,'__');
						n.className=n.className+' '+n.tc;
					}else{
						cl($(n+'-content'));
						cc($(n+'-header'),'');
					}
				}
			}
			if(h.className.match(/selected+/)!=undefined){ sel=h;}
		}
	}
	if(sel!=undefined){sel.onclick();}
}
</script>


<div class="cont-miolo">
	<?php 		
	include_once TEMPLATEPATH.'/av-define.php';
	include_once PDO.'/NextGenPDO.class.php';
	$ng = new NextGenPDO ();
	$linha = $ng->galeria_id_by_author($post->post_author);		// gid, name, previewpic, author - gallery
	$galeria_picture_tudo = $ng->galeria_get_picture_source();	// filename, path, gid, author, name - gallery_pictures
	?>
	<div class="vertical_space_20"></div>
	<h1 class="font-azul">Feiras Locais</h1>
	<div class="vertical_space_20"></div>

	<div style="width: 620px; text-align:justify;">
		<p>
			Nas feiras semanais ou mensais encontram-se à venda variadas espécies de aves,
			bem como gaiolas e outros acessórios, alimentos, etc. Existem em várias localidades 
			de Portugal, veja em baixo a mais próxima de si. 
		</p>
	</div>
	<div class="vertical_space_35"></div>

	<div id="basic-accordian" >		
		
		<div id="test-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Braga' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<div class="vertical_space_10"></div>
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<div class="vertical_space_10"></div>
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>					
			</div>
		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test1-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Barcelos' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test1-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test2-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira do Porto' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test2-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test3-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Tondela' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test3-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>

		<div id="test4-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Vizela' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test4-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<div class="vertical_space_10"></div>
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<div class="vertical_space_10"></div>
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test5-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira do Rio Meão' ); 
			echo strtoupper_utf8(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test5-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test6-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Guimarães' ); 
			echo strtoupper_utf8(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test6-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test7-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Estela - P. Varzim' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test7-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>

		<div id="test8-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Paços de Ferreira' ); 
			echo strtoupper_utf8(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test8-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<div class="vertical_space_10"></div>
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<div class="vertical_space_10"></div>
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test9-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Pinhal Novo' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test9-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test10-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Mavra (Malveira)' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test10-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test11-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Mavra (Encarnação)' ); 
			echo strtoupper_utf8(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test11-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>

		<div id="test12-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Lisboa' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test12-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<div class="vertical_space_10"></div>
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<div class="vertical_space_10"></div>
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test13-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Sintra' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test13-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test14-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Montijo' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test14-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>
		
		<div id="test15-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Barreiro' ); 
			echo strtoupper(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test15-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>

		<div id="test16-header" class="accordion_headings header_highlight">
			<?php $page = get_page_by_title( 'Feira de Valença' ); 
			echo strtoupper_utf8(get_post_meta($page->ID, 'avpt_feiras_cidade', true));
		    ?>
		</div>
		<div id="test16-content">
			<div class="accordion_child">
				<div style="float:left; width=300px;">
					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/calendar.png" width="28" height="28" />&nbsp;
					<span class="preto22">Dia / Horário</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_dia_hora', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				    
				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/promo_green.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Organização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_organizacao', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/telephone.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Quem Contactar</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_quem_contactar', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/laptop.png" width="28" height="28" />&nbsp;
				    <span class="preto22">Página Web</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_end_web', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<a href="<?php echo ($pedaco[$i]);?>" target="_blank">
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
						</a>
					<?php	
				    }
				    ?>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />
				</div>

				<div style="float:right; width=300px;">

					<img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/home.png" width="28" height="28" />&nbsp;
					<span class="preto22">Localização</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_endereco', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    $variavel = preg_replace('/\s/',' ',get_post_meta($page->ID, 'avpt_feiras_endereco', true)); ?>
			    	<script type="text/javascript">
			    	var variavel = new Array();
					variavel['teste'] = "<?=$variavel;?>";
    				$(function(){
    					$('#mapa').gmap3({
 							map: {
    							options: {
    								maxZoom: 18
    							}  
 							},
 							marker:{
    							address: variavel['teste']
    						}
						},
						"autofit");
   	 				});
    				</script>  
    				<div id="mapa" class="gmap3"></div>
				    <hr style="margin-top: 20px; border-bottom: 0.1000px solid #eee; width:280px;" />
				    <br />

				    <img alt="" src="<?php echo bloginfo('template_directory')?>/images/icon/map_blue.png" width="28" height="28" />&nbsp;
					<span class="preto22">Pontos de Referência</span>
					<br />
					<?php 
					$pedacos = get_post_meta($page->ID, 'avpt_feiras_pto_referencia', true);
					$pedaco = explode(';', $pedacos);
					$size = sizeof($pedaco);
					for ($i = 0; $i <= $size; $i++) { ?>
						<br />
						<span class="azul14"><?php echo ($pedaco[$i]);?></span>
					<?php	
				    }
				    ?>
				    <br />
				</div>
					
			</div>

		</div>
		<div class="vertical_space_10"></div>								
		
		
	</div><!--End of accordion parent-->
	








	<div class="vertical_space_30"></div>
	
	<div class="cont-outra-info">
		<br /></br>
		<div style="width: 610px; float: right; font-size: 24px;">Outras Informações</div>
		<br /></br><br />
		<span class="azul18">Título</span>
		<br /><br />
		<span class"preto16"><?php echo get_post_meta($post->ID, 'avpt_parques_zoos_outras_info', true); ?></span>
 	</div>
	<div class="clr"></div>	

	<div class="vertical_space_30"></div>
	
	<div class="cont-outra-info">
		<br /></br>
		<div style="width: 610px; float: right; font-size: 24px;">Outras Informações</div>
		<br /></br><br />
		<span class="azul18">Título</span>
		<br /><br />
		<span class"preto16"><?php echo get_post_meta($post->ID, 'avpt_parques_zoos_outras_info', true); ?></span>
 	</div>
	<div class="clr"></div>	

	<div class="vertical_space_30"></div>


</div><!-- Fim div cont-miolo -->

























<div id="direita">
	<?php dynamic_sidebar( 'Lateral Direita Home' ); ?>
	<div class="vertical_space_20"></div> 
</div><!-- Fim div coluna_direita -->


<div class="cont-direitos" style="border-top: 2px #efefef solid;">
	<?php direito_barra_page ("Página de detalhes do ", get_the_title()); ?>
</div>

</div><!-- Fim div corpo -->
<div class="vertical_space_20"></div>

<div class="cont-miolo-pub"><?php add_google_pub_bloco_2x468x60 (); ?></div>
<div class="vertical_space_20"></div>

</div><!-- Fim div tudo -->

<?php get_footer(); ?>

</body>

</html>